
package jpoco.internal.gson;

import com.google.gson.*;
import jpoco.client.*;

public class GsonFactory
{
	static public Gson createGson()
	{
		GsonBuilder builder = new GsonBuilder();
		
		builder.registerTypeAdapter(java.util.Calendar.class, new CustomCalendarTypeAdapter(XmlDateTime.XML_SCHEMA_DATETIME_PATTERN));
		builder.registerTypeAdapter(jpoco.client.Relationship.class, new RelationshipTypeAdapter());

		Gson gson = builder.create();
		
		return gson;
	}
}
